package com.maoyu.cloud.login.controller;


import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import javax.servlet.http.HttpServletRequest;

@Controller
@RequestMapping("/login")
public class LoginController {

    @RequestMapping("/login")
    public String Login(HttpServletRequest httpServletRequest) {

        httpServletRequest.getSession().setAttribute("siteLanguage",LocaleContextHolder.getLocale().toString());
        return "login/loginPage";
    }

    @RequestMapping("/main")
    public String loginMain(){
        return "redirect:/";
    }


}
